package com.dfbz.bigdata.modules.system.doman;



import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 
 * @TableName tb_designer_case
 */
@TableName(value ="tb_designer_case")
@Data
public class DesignerCase implements Serializable {
    /**
     * 主键
     */
    @TableId
    private Long caseId;

    /**
     * 案例标题
     */
    private String caseTitle;

    /**
     * 分类id
     */
    private Long categoryId;

    /**
     * 图片
     */
    private String caseImage;

    /**
     * 描述信息
     */
    private String caseDescription;

    /**
     * 风格id
     */
    private String caseStyleId;

    /**
     * 色系
     */
    private String caseColor;

    /**
     * 地点
     */
    private String casePlace;

    /**
     * 作者
     */
    private Long caseAuthorId;

    /**
     * 创建时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(shape=JsonFormat.Shape.STRING,pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date updateTime;

    /**
     * 创建人
     */
    private Long createUser;

    /**
     * 修改人
     */
    private Long updateUser;

    /**
     * 是否删除
     */
    private Integer isDeleted;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DesignerCase other = (DesignerCase) that;
        return (this.getCaseId() == null ? other.getCaseId() == null : this.getCaseId().equals(other.getCaseId()))
            && (this.getCaseTitle() == null ? other.getCaseTitle() == null : this.getCaseTitle().equals(other.getCaseTitle()))
            && (this.getCategoryId() == null ? other.getCategoryId() == null : this.getCategoryId().equals(other.getCategoryId()))
            && (this.getCaseImage() == null ? other.getCaseImage() == null : this.getCaseImage().equals(other.getCaseImage()))
            && (this.getCaseDescription() == null ? other.getCaseDescription() == null : this.getCaseDescription().equals(other.getCaseDescription()))
            && (this.getCaseStyleId() == null ? other.getCaseStyleId() == null : this.getCaseStyleId().equals(other.getCaseStyleId()))
            && (this.getCaseColor() == null ? other.getCaseColor() == null : this.getCaseColor().equals(other.getCaseColor()))
            && (this.getCasePlace() == null ? other.getCasePlace() == null : this.getCasePlace().equals(other.getCasePlace()))
            && (this.getCaseAuthorId() == null ? other.getCaseAuthorId() == null : this.getCaseAuthorId().equals(other.getCaseAuthorId()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getCreateUser() == null ? other.getCreateUser() == null : this.getCreateUser().equals(other.getCreateUser()))
            && (this.getUpdateUser() == null ? other.getUpdateUser() == null : this.getUpdateUser().equals(other.getUpdateUser()))
            && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getCaseId() == null) ? 0 : getCaseId().hashCode());
        result = prime * result + ((getCaseTitle() == null) ? 0 : getCaseTitle().hashCode());
        result = prime * result + ((getCategoryId() == null) ? 0 : getCategoryId().hashCode());
        result = prime * result + ((getCaseImage() == null) ? 0 : getCaseImage().hashCode());
        result = prime * result + ((getCaseDescription() == null) ? 0 : getCaseDescription().hashCode());
        result = prime * result + ((getCaseStyleId() == null) ? 0 : getCaseStyleId().hashCode());
        result = prime * result + ((getCaseColor() == null) ? 0 : getCaseColor().hashCode());
        result = prime * result + ((getCasePlace() == null) ? 0 : getCasePlace().hashCode());
        result = prime * result + ((getCaseAuthorId() == null) ? 0 : getCaseAuthorId().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getCreateUser() == null) ? 0 : getCreateUser().hashCode());
        result = prime * result + ((getUpdateUser() == null) ? 0 : getUpdateUser().hashCode());
        result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", caseId=").append(caseId);
        sb.append(", caseTitle=").append(caseTitle);
        sb.append(", categoryId=").append(categoryId);
        sb.append(", caseImage=").append(caseImage);
        sb.append(", caseDescription=").append(caseDescription);
        sb.append(", caseStyleId=").append(caseStyleId);
        sb.append(", caseColor=").append(caseColor);
        sb.append(", casePlace=").append(casePlace);
        sb.append(", caseAuthorId=").append(caseAuthorId);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", createUser=").append(createUser);
        sb.append(", updateUser=").append(updateUser);
        sb.append(", isDeleted=").append(isDeleted);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}